package com.shen.web.action;

import com.shen.service.LoginService;


/**
 * 登录action
 * @author shen
 *
 */
//@ParentPackage(value = "struts-default")
//@Namespace(value = "/background")
//@Action(value="login")
//@Results(value = { @Result(name="SUCCESS",location="/result.jsp") })
public class LoginAction extends BaseStruts2Action {
	private static final long serialVersionUID = 4754898766694736793L;
	
	private String xm;
	private String password;
	
	private LoginService loginService;
	
	/**
	 * 登录
	 * @return
	 */
	public String login(){
//		if(loginService.checkUser(xm, password)){
			return "success";
//		}else{
//			throw new RuntimeException("---------");
//		}
		
	}

	public String getUsername() {
		return xm;
	}

	public void setUsername(String xm) {
		this.xm = xm;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public void setLoginService(LoginService loginService) {
		this.loginService = loginService;
	}
	
}
